package com.tulingxueyuan.mall.modules.oms.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.tulingxueyuan.mall.dto.OmsOrderViewDTO;
import com.tulingxueyuan.mall.dto.OrderConditionDTO;
import com.tulingxueyuan.mall.dto.OrderReceiverInfoDTO;
import com.tulingxueyuan.mall.dto.OrderUpdateStatusDTO;
import com.tulingxueyuan.mall.modules.oms.model.OmsOrder;

import java.util.List;

/**
 * <p>
 * 订单表 服务类
 * </p>
 *
 * @author XuShu
 * @since 2023-05-28
 */
public interface OmsOrderService extends IService<OmsOrder> {

    /**
     * 订单条件分页
     * @param orderConditionDTO
     * @return
     */
    Page listPage(OrderConditionDTO orderConditionDTO);

    Boolean updateShipment(List<OrderUpdateStatusDTO> list);

    Boolean updateSReceiver(OrderReceiverInfoDTO orderReceiverInfoDTO);

    /**
     * 修改备注
     * @param omsOrder
     * @return
     */
    Boolean updateNote(OmsOrder omsOrder);

    /**
     * 取消订单
     * @param ids
     * @param note
     * @return
     */
    Boolean closeOrder(List<Long> ids, String note);

    OmsOrderViewDTO getByIdWithOrderItem(Integer id);
}
